package com.koicarp.agent.example.aiservices2.output;

import com.koicarp.agent.example.ChatModelInit;

import dev.langchain4j.model.chat.ChatModel;
import dev.langchain4j.service.AiServices;

/**
 * @Author: liuxia
 * @CreateTime: 2025/9/23 下午20:13
 * @Description: 布尔值输出 test
 */
public class BooleanOutputTest {

	public static void main(String[] args) {
		ChatModel chatModel = ChatModelInit.initOllamaQwen();		// 使用qwen模型，deepseek模型会返回think内容会导致接受失败
		
		Assistant2 as = AiServices.create(Assistant2.class, chatModel);
		boolean isHave = as.chatBoolean("上海有东方明珠吗？");
		System.out.println(isHave);									// true
	}
}
